package org.bigjava.biz.impl;

import org.bigjava.bean.Garbage;
import org.bigjava.biz.GarbageService;
import org.bigjava.mapper.GarbageMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("garbageService")
public class GarbageServiceImpl implements GarbageService {
    @Qualifier("garbageMapper")
    @Autowired
    GarbageMapper garbageMapper;
    //根据垃圾站点编号或者垃圾站点名称查询
    @Override
    public List<Garbage> garbageMoHu(String zdbh, String zname) {
        return garbageMapper.garbageMoHu(zdbh,zname);
    }
//修改垃圾站点信息
    @Override
    public int garbageXiuGai(Garbage garbage) {
        return garbageMapper.garbageXiuGai(garbage);
    }
//根据id查询垃圾站点信息
    @Override
    public Garbage garbageId(int id) {
        return garbageMapper.garbageId(id);
    }
//删除垃圾站点
    @Override
    public int garbageShanChu(int id) {
        return garbageMapper.garbageShanChu(id);
    }
//垃圾站点总数
    @Override
    public int garbageZong() {
        return garbageMapper.garbageZong();
    }
//分页查询垃圾站点信息
    @Override
    public List<Garbage> garbageFenYe(int offset, int length) {
        return garbageMapper.garbageFenYe(offset,length);
    }
//添加垃圾站点
    @Override
    public int garbageAdd(Garbage garbage) {
        return garbageMapper.garbageAdd(garbage);
    }
//全查出垃圾站点
    @Override
    public List<Garbage> garbageQuan() {
        return garbageMapper.garbageQuan();
    }
}
